<?php
/**
 * Created by PhpStorm.
 * User: Hongjw
 * Date: 2018/3/15
 * Time: 9:50
 */

namespace App\Http\Controllers\Laravel\HelpFun;


use App\Http\Controllers\Controller;
use App\Tools\Controller\ControllerMethodRoute;
use Hash;

class FastFunController extends Controller
{
    use ControllerMethodRoute;
    public $home = '/laravel/helpfun/fast/';

    public function myBcrypt(){
        /**
         * laravel Hash::make()生成的密码每次刷新每次变动
         * 要用Hash::check()检测
         * 可以参考PHP自带的password_hash和password_vertify去理解
         */
        $str1 = 123123;
        $strB = bcrypt($str1);
        $strH = Hash::make($str1);
        dump($strB,$strH,$strB == $strH,Hash::check($str1,'$2y$10$loWhpVWmsGocMfWlbSW3iuCbC63BwbU1IqcEQ8rYjuumnBbSagRIe'));
    }


}